package Person.Lambda;

public class FlyableDemo {
    public static void main(String[] args) {
        useFlyable(new Flyable() {
            @Override
            public void fly(String s) {
                System.out.println(s);
            }
        });
        System.out.println("-------------");
        //lambda
        useFlyable((String s) ->{
            System.out.println(s);
            System.out.println("易烊千玺");
        });
    }
    private static void useFlyable(Flyable f){
        f.fly("风和日丽，晴空万里");
    }
}
